package com.accp.restaurant.dao;

import com.accp.restaurant.entity.Staff;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;

public interface StaffDao extends JpaRepository<Staff,Long> {

    @Query(value = "select * from Staff  where  staffname =:Staffname",nativeQuery = true)
    public Staff Login(@Param("Staffname") String Staffname);


    public Staff findByRole_Roleid(long roleid);
}
